package com.zxs.common.enums;

import lombok.Getter;

/**
 * 删除状态的枚举
 * @author zxs
 * @date 2025/11/8 下午1:30
 */
@Getter
public enum CategoryTypeCodeEnum {
    SECOND(2, "二级分类"),
    PRIMARY(1, "一级分类（岗位）");

    private int code;
    private String msg;

    CategoryTypeCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public static CategoryTypeCodeEnum getResultCodeEnum(int code) {
        for (CategoryTypeCodeEnum resultCodeEnum : CategoryTypeCodeEnum.values()) {
            if (resultCodeEnum.getCode() == code) {
                return resultCodeEnum;
            }
        }
        return null;
    }

}